<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=0.5, minimum-scale=0.5, maximum-scale=0.5, user-scalable=no">
<link rel="stylesheet" href="//at.alicdn.com/t/font_342477_owwvl7ndgo.css?v=1.0.0">
<title>邀请代理</title>
<link type="text/css" rel="stylesheet" href="/static/css/s.common.css">
<link type="text/css" rel="stylesheet" href="/static/css/s.agent.css">
<script type="text/javascript" src="/static/js/jquery.min.js"></script>
<script type="text/javascript" src="/static/js/layer_mobile/layer.js"></script>
<script type="text/javascript" src="/static/js/common.js"></script>
<style type="text/css">
html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}
body{margin:0}
html{font-size:50px}
body{
-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;font-size:32px;background-color:#f5f5f9
}
body{line-height:40px!important;font-size:26px!important}
body,body.g-init-echart{font-family:Microsoft YaHei,Helvetica!important;color:#2e3136;background:#f5f6f7!important}

.c-share-back {
    position: fixed;
    width: 100%;
    left: 0;
    right: 0;
    margin: auto;
    bottom: 200px;
    z-index: 9;
    padding-left: 50px;
}
.c-share-back .__content {
    float: left;
    width: 70px;
}
.c-share-back .__icon {
    float: right;
    border-radius: 100%;
    text-align: center;
    background: rgba(0,0,0,.5);
    line-height: 70px;
    height: 70px;
    width: 70px;
    margin-top: -70px;
    color: #fff;
    font-size: 50px;
}

.v-invite-group-level .g-bg-lgr-orange ._recommend, .v-invite-group-level .g-bg-white ._recommend {
    margin-left: 20px;
    font-size: 22px;
    background-color: #000;
    color: #fae1a4;
    display: inline-block;
    border-radius: 18px;
    text-align: center;
    padding: 0 15px;
}
.layui-layer-loading .layui-layer-content{ width:120px; height:48px; background-size:cover; }
.layui-m-layer-msg .layui-m-layercont{ font-size:28px; line-height:44px; padding:20px 40px;}
.layui-m-layer2 .layui-m-layercont i{ background:#5c8dff; }
</style>
<script>
$(function(){
	$('.g-m-t-20').click(function(){
		if($(this).hasClass('g-bg-white')){
			$(this).removeClass('g-bg-white').addClass('g-bg-lgr-orange');
			$('.g-fs-26',this).removeClass('g-black-middle');
			$('.g-fs-26',this).find('span').removeClass('g-orange-dark');
			$(this).append('<div class="g-ai-c g-flex"><i class="iconfont icon-past"></i></div>');
		}else{
			$(this).removeClass('g-bg-lgr-orange').addClass('g-bg-white');
			$('.g-fs-26',this).addClass('g-black-middle');
			$('.g-fs-26',this).find('span').addClass('g-orange-dark');
			$('.g-flex',this).remove();
		}
	});
	$('.btn-create').click(function(){
		let ids = new Array();
		$('.levelitem').each(function(){
			if($(this).hasClass('g-bg-lgr-orange')){
				ids.push($(this).attr('data-id'));
			}
		});
		if(ids.length < 1){
			layerMsg('请选择代理级别'); return;
		}
		location.href = "{:url('Agent/invite_create')}?agent_id={$Think.const.AGENT_ID}&levels="+ids.join(",");
	});
});
</script>
</head>
<body>

<div id="pages">
    <div>
        <div>
            <title>邀请代理</title>
            <div class="g-pd">
                <div class="g-m-b-20 g-pd-b">
                    <p>邀请代理想代理的产品(单选):</p>
                    <div>
                        <div class="g-bg-lgr-orange item-radius g-pd g-flex g-jc-sb g-m-t-20">
                            <div class="">
                                <p class="g-fs-32">娜纹</p>
                                <p class="g-fs-26">娜纹</p>
							</div>
                            <div class="g-ai-c g-flex">
                                <i class="iconfont icon-past"></i>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="v-invite-group-level g-pd-t">
                    <p>您想邀请代理的级别(可单选或多选):</p>
					{volist name='levellist' id='v'}
                    <div>
                        <div class="g-bg-white item-radius g-pd g-flex g-jc-sb g-m-t-20 levelitem" data-id="{$v.agentlevelid}">
                            <div class="">
                                <p class="g-fs-32">{$v.agentlevelname}
                                    <span class="_recommend">{if condition="$v.level gt 0"}跨级推荐{elseif condition="$v.level eq 0" /}平级推荐{/if}</span></p>
                                <p class="g-fs-26 g-black-middle">首次货款充值金额至少达到：
                                    <span class="g-orange-dark">￥{$v.firstbuyminamount|floatval}</span>元</p>
								 <p class="g-fs-26 g-black-middle">保证金金额至少达到：
                                    <span class="g-orange-dark">￥{$v.depositamount|floatval}</span>元</p>
							</div>
                        </div>
                    </div>
					{/volist}
                    
					<div style='height:90px;'></div>
                </div>
                <div class="g-fixed-content g-flex btn-create">
                    <a class="g-bg-blue g-lh-88 g-tc g-col" style="display: block;">生成邀请链接</a>
				</div>
            </div>
			
            <div class="c-share-back">
                <div class="__content">
                    <i class="iconfont icon-goback __icon"></i>
                </div>
            </div>
			
        </div>
    </div>
</div>


</body>
</html>